Search and Retrieval Methods and Systems of Short Messages Utilizing Messaging Context and Keyword Frequency

ABSTRACT

Systems and methods of identifying and retrieving messages that satisfy a search query using the context of the message and term frequencies are provided. One embodiment includes identifying at least one category relevant to the search query, wherein a plurality of scored keywords are associated with each category, selecting at least one of the scored keywords that is relevant to an identified category, performing a plurality of searches of messages from a social networking messaging service to retrieve messages, where at least one search includes retrieving messages based on the original search query and one of the selected scored keywords, scoring the retrieved messages with respect to each of the at least one identified categories using at least the scored keywords relevant to each category, and returning at least the message with the highest score as the search result.

CROSS REFERENCE TO RELATED APPLICATIONS

This application is a continuation of U.S. application Ser. No. 12/909,576 filed Oct. 21, 2010, which application claims the benefit of U.S. Provisional Patent Application No. 61/253,720, filed on Oct. 21, 2009, the disclosure of which is hereby incorporated by reference as if set forth in full herein.

BACKGROUND

The invention generally relates to messaging in social networks, and more particularly relates to searching and retrieving messages using messaging context and keyword frequency.

The Internet is a tremendous source of information, but finding a desired piece of information has been the preverbal “needle in the haystack”. For example, services like blogs provide data miners a daunting task of perusing through extensive amounts of text in order to find data that can become applicable for other uses. Hence, text data mining and information retrieval systems designed for large collections of lengthy documents have arisen out of the practical need of finding a piece of information in the massive collections of varied documents (such as the World Wide Web) or in databases of professional documents (such as medical or legal documents). Likewise, with the popularity of social networking increasing every day, the amount of user-generated content from these social networking sites continues to grow. Thus, finding information that is relevant and useable is quickly becoming more difficult.

These popular social networking services or options, like Twitter messages or Facebook statuses, are typically much shorter in length than full web pages. This brevity however makes it increasingly difficult to use current filtering techniques specifically designed to sort through large amounts of data. For example, popular techniques, such as term frequency-inverse document frequency (TF-IDF) weighting, are dependent on both the collection of information, as well as the average document size, to be large.

Additionally, in recent years there has been an increase in the number of very short documents, usually in the form of user generated messages or comments. Typical user generated messages have come from a number of sources, for example, instant messaging programs, such as AOL instant messenger; online chat rooms; text messages from mobile phones; message publication services, such as Twitter; and “Status” messages, such as those on Facebook pages. Thus, with the rising popularity of these messaging services, there has become a need to search the messages for their content. Some techniques of searching short messages consist simply of doing regular expression matching. However, these techniques typically fail when a term being searched is ambiguous and/or used in unrelated topics. For example, searching for “Amazon” could result in finding messages about the Amazon river and the online retailer, Amazon. Also, if additional terms are provided, many relevant messages may be omitted. For example, searching for “Amazon river” would not match the message “Hiked to the Amazon today—what a beautiful jungle this is”, whereas a webpage or a large document about the Amazon River would likely contain both the words “Amazon” and “river”, while a short message may not.

Additionally, due to the tremendous volume of messages flowing through a social media network, the number of messages that can be stored over a period of time can be quite substantial. Searches looking for a particular word or words in messages can result in a similarly large search result of identified messages within a relatively small time period. For example, the more common the term the shorter the time period and/or the larger the number of most recent messages. Also, as previously noted, ambiguous terms, e.g., “Amazon” or “tool”, can also cause additional issues e.g., false positives.

Accordingly, there is a need to provide a message searching and retrieval system to identify relevant short messages while overcoming the obstacles and shortcomings previously noted and recognized in the art.

SUMMARY

Generally, systems and methods of identifying and retrieving messages that satisfy a search query using the context of the message and term frequencies are provided. One embodiment includes identifying at least one category relevant to the search query, wherein a plurality of scored keywords are associated with each category, selecting at least one of the scored keywords that is relevant to an identified category, performing a plurality of searches of messages from a social networking messaging service to retrieve messages, where at least one search includes retrieving messages based on the original search query and one of the selected scored keywords, scoring the retrieved messages with respect to each of the at least one identified categories using at least the scored keywords relevant to each category, and returning at least the message with the highest score as the search result.

In a further embodiment, the user indicates at least one category relevant to the search query.

In another embodiment, the query is scored with respect to each category using the scored keywords associated with each category and at least one category is identified based upon the query score.

In a yet further embodiment, selecting at least one of the scored keywords that is relevant to an identified category includes selecting a plurality of scored keywords relevant to an identified category, and performing a plurality of searches of messages from a social networking messaging service further includes performing a separate search for each of the selected scored keywords, where each search includes retrieving messages based on the original search query and the selected scored keyword.

In yet another embodiment, performing a plurality of searches of messages from a social networking messaging service further includes performing a search, where the messages are retrieved based on the original search query.

In a still further embodiment, scoring the retrieved messages with respect to each of the at least one identified categories using the scored keywords relevant to each category further includes excluding any scored keyword used in the search that retrieved the message from the scoring of the message.

In still another embodiment, the searches include performing expression matching.

In a further embodiment again, the searches include scoring the message with respect to the original search query and the selected scored keyword.

In another embodiment again, scoring the retrieved messages further includes weighting messages based upon the amount of time that has elapsed since the message was posted.

The above-mentioned and other features of this invention and the manner of obtaining and using them will become more apparent, and will be best understood, by reference to the following description, taken in conjunction with the accompanying drawings. The drawings depict only typical embodiments of the invention and do not therefore limit its scope.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a block diagram illustrating a messaging search and retrieval system in accordance with various embodiments of the invention.

FIG. 2 is a flowchart illustrating a messaging classification or topic generation process in accordance with various embodiments of the invention.

FIG. 3 is a flowchart illustrating a messaging search and retrieval process in accordance with various embodiments of the invention.

FIG. 4 is a flowchart illustrating a messaging search and retrieval process in accordance with various embodiments of the invention.

DESCRIPTION

In various embodiments, methods and systems are provided to enhance searching of messages in a social network. In one embodiment, a user provides a search query. Given the search query, topic relevance is utilized to determine a particular topic or topics appropriate for the search query. In another embodiment, the user specifies the desired topic the search results should fall into. In one embodiment, topics or categories are set up with associated keywords in which short messages are identified and placed in an appropriate category. In various embodiments, categories are subject or topic containers that include, but are not limited, to a person, place or thing. Keywords extracted from short messages that are relevant to a category are associated with the corresponding category. With the topic and extracted keywords, one or more (“N”) parallel searches are conducted to assist in locating the relevant messages. Such searches include but are not limited to the following:

-   -   Original query that comprises the search query for information         on a specific topic.     -   Original query plus high frequency first keyword from the         identified topic.     -   Original query plus high frequency second keyword from the         identified topic.     -   Original query plus high frequency last keyword from the         identified topic.

The number of concurrent searches may be limited to the highest frequency N keywords to limit the time it takes to conduct the search.

Subsequently, each message for a given topic is scored and ranked by score. The most relevant and, in some cases, the most recent relevant messages are returned to the searcher, e.g., a user or client system, that provided the search query. In order for fair scoring, the additional keyword may not be counted in the scoring of the message.

Categories and Keywords

In one embodiment, categories of interest are generated by identifying a specific subject or topic, such as a person, place or an object. The categories in one embodiment are refined based on usage performance. In particular, categories focused on things perform well with narrower descriptions having a better performance. For example, a category such as “sports” would not perform as well as “basketball”, which would not perform as well as “UCLA basketball”. These fine grained categories however can come at the cost of increased processing time and storage. In one embodiment, each category is unique having no overlap with other categories.

For each category generated, one or more keywords are identified and associated with each category. In one embodiment, keywords are stored in tables in which each category may have multiple tables. The keywords that are stored come from messages in the desired medium. As such, in one embodiment, within each category, there is a specific table with one or more specific keywords for each medium. Each medium, e.g., messaging service, can have different message formats and/or terminology used. For example, text messages from a mobile phone can and will often look quite different from messages posted to Facebook. Thus, keywords from other sources in one embodiment are only used as a search query into the desired message format. In this way the keyword tables can account for slang terms and other such differentiators specific to the medium. In a number of embodiments, one or more of the following processes can be used to identify the keywords.

Unambiguous Training

For a given category, e.g., musical artists, there can be ambiguous and unambiguous terminology. For example, an artist name can be ambiguous (“the Beatles”) or unambiguous (“Paul McCartney”). Utilizing unambiguous terminology, every keyword used in a message containing “Paul McCartney” would be stored, and the usage frequencies of the keywords would be used as a measure of how related to the musical artist category a given query would be.

User Tagging

A message database in one embodiment would allow for manual tagging of information. These tags are created by users as a means to self-classify messages. One example is preceding a tag name with a unique character, e.g., a “#” character. For example, if a message contains “#oscars”, then presumably the message is about the Oscars awards ceremony. As such, keywords about the Oscars awards ceremony can be generated by finding every message with the “#oscars” tag, and store each of the keywords present in the located messages. The resulting table would thus include words commonly used to describe the ceremony, and thus a message that did not have a “#oscars” tag can be located using the table.

Third-Party Information

In one embodiment, a third party database or similar resource can be used to identify keywords. For example, utilizing a resource, such as Wikipedia, as a large collection of words related to a category, a TF-IDF analysis of this resource would yield the most important keywords for a given category. Messages could be searched to locate messages that used these keywords in which each of the resulting message-based keywords are stored in the associated category's table.

Category and Message Scoring

A message score for a given category is a measure of how likely its keywords are present in all the messages related to the category. The message scores are defined by

${{score}\left( {m,c} \right)} = {\sum\limits_{g \in m}\; {f\left( {P\left( {g,c} \right)} \right)}}$

where m is a given message, c is a given category, g is a keyword in the message, and P(g,c) is the normalized frequency of a message in category c containing the keyword g. The function f is a thresholding or quantization function.

Quantization Function f

Most category tables have probability distributions that follow a power-law distribution. However, the resulting tables may have a large number of small values, or conversely, a small number of large values. In such cases it may be helpful to pass this table through a quantization function. The simplest function is simply a threshold, by which any keywords that do not pass the threshold have frequencies set to 0. More complex quantizers are used to simplify the table, boost certain values, or otherwise be shaped to improve the scoring performance.

A final message score is defined as w_(score)·score(m,c_(q))+w_(match)·match(m,q), where w is a weight [0 . . . 1], score(m,c_(q)) is the score of the message in the query's category, and match(m,q) is the percentage of keywords that match between message m and the query q. This value is used to ensure that the messages have some similarity to the query, even if they both score high in a category.

Referring now to an example, if the query is “Amazon river”, then this query would rank high in a category about rivers, the Amazon jungle, or even geographical categories. This query however would score lower in categories about companies, as the term “river” would not occur very frequently in these categories. Similarly, the message “Hiked to the Amazon today—what a beautiful jungle this is” would also rank high in the category of geographical messages, as the keywords “hiked” and “jungle” would appear often in such categories. Finally, the message matches 50% of the terms in the query (i.e., “Amazon”), ensuring that the message has a relation to the query and not just the category as a whole.

Referring now to drawings, a message classification and retrieval system is shown in FIG. 1. The system includes a message server 3 that is coupled with a message database 5 and is in network communication with a plurality of messaging services and information sources 7. The message server receives user generated messages from the plurality of messaging services and information sources. The received messages are stored in category records in the message database and keywords are selected from the received messages and associated with the category records. The message server also scores each message which is stored in the message database and associated with the corresponding category records. Although the system is shown as storing messages, in many embodiments messages are retrieved from the messaging service(s) as needed.

The message server 3 also receives search queries externally from, for example, messaging services or web servers or internally, for example, through a user interface in communication with the message server. For each received search query, the message server calculates a score that identifies a specific category. Utilizing the score, the server retrieves the associated category record from the message database. Messages stored or associated with the category record is retrieved by the server and transmitted back to a designated recipient, e.g., the sender of the search query. In one embodiment, the message server calculates or retrieves a final message score for the identified category for the stored messages. Utilizing the final message score, the server selects specific messages stored or associated with the category record for transmission to a designated recipient.

In FIG. 2, a messaging classification generation process in accordance with various embodiments of the invention is illustrated. Initially, categories are first determined (21). Keywords are identified and used to populate tables for each determined category (22). In one embodiment, a medium is identified and used to select tables in which to populate with the keywords identified. Each message received is scored for each determined category (23).

Referring now to FIG. 3, a messaging search and retrieval process starts with a search query being received (31). The query is scored for each category (32) and the category with the highest query score is selected (33). Messages with the highest score in this category and that contain some of the matched terms are returned as the message search results (34). In one embodiment, terms or words are extracted from the query and matched to keywords for the determined category.

Referring back to the “Amazon river” query example, two potential categories are established. It should be appreciated that the number of categories may be varied and numerous along with the associated keywords and messages, but are shown here in a limited fashion to facilitate the description of the invention. It should also be appreciated that although unigrams are largely described, bigrams or two words being considered as a single token, e.g., keyword or category, can also be utilized. Multiple or “N” words can also be used however there can be a diminishing return as more words are used. The first category is a geographical location category and the second category is a company category. As shown in the following tables, each category includes a set of keywords with associated normalized keyword frequency calculations.

TABLE 1 Geographical Location Normalized Keyword Frequency Keywords 0.2 river . . . . . . 0.05 jungle 0.05 Amazon 0.005 hike

TABLE 2 Company Normalized Keyword Frequency Keywords 0.5 revenue 0.2 employee 0.01 Amazon . . . . . . 0.0005 jungle 0.0001 hike

Utilizing the tables and in particular matching the keywords of each category with the terms in the search query, a query score is determined utilizing the associated normalized keyword frequency calculations. For example, the query score for the geographical location category is 0.25 (0.2 (river)+0.05 (Amazon)). Likewise, the query score for the company category is 0.01 (0.01 (Amazon)+0 (river)).

Given a first message, “Hiked to the Amazon today, what a beautiful jungle this is” and a second message, “Amazon announced revenue up 38%”, messages scores can also be generated by matching keywords for each category and utilizing the associated normalized keyword frequency calculations. For example, the message score for the first message in the geographical category is 0.105 (0.05 (jungle)+0.05 (Amazon)+0.005 (hike)) and in the company category is 0.0106 (0.01 (Amazon)+0.0005 (jungle)+0.0001 (hike)). The second message score for the geographical category is 0.05 (Amazon) and for the company category 0.51 (0.5 (revenue)+0.01 (Amazon)).

Since the query score for the geographic category (0.25) is higher or larger than the query score for the company category (0.1), the geographic location category is selected to utilize the message scores for each of the messages. Thus, score (m1, geographic)=0.105 and score (m2, geographic)=0.05, where m1 and m2 are respective first and second messages. Since in the provided example, the search query is short, only one term matches, i.e., Amazon. Thus, the match values for each message are match(m1, q)=0.5 and match(m2, q)=0.5, where q is the query. Accordingly, the final score disregarding weight factors shows that the first message has a final score of 0.605 (0.105+0.5) greater than the final score of 0.55 (0.05+0.5) for the second message. Thus, the first message being the most relevant is provided as the search result for the given search query.

Referring now to FIG. 4, in one embodiment, a messaging search and retrieval process starts with a search query being received (41). A desired topic is also received (42). In one embodiment, the query is scored for each category and the category with the highest query score is selected as the desired topic. Utilizing the query and keywords from the desired topic, multiple searches are then conducted (43). In one embodiment, the multiple searches are parallel searches that retrieve messages that match the search query and iterative combinations of the search query and each of the top keywords from the desired topic. Retrieved or identified messages are scored (44) and sorted by score (45). Messages are placed or stored into equal size containers or bins or otherwise associated into groups in a storage medium or database (46). The messages in the top “N” number of bins messages are returned as the message search results (47). In one embodiment, the “N” number of bins are defined by a user's preference or predetermined by the messaging and retrieval system based on for example an estimated or determined processor or resource utilization or availability.

Although the present invention has been described in certain specific aspects, many additional modifications and variations would be apparent to those skilled in the art. It is therefore to be understood that the present invention may be practiced otherwise than specifically described, including various changes in the size, shape and materials, without departing from the scope and spirit of the present invention. Thus, embodiments of the present invention should be considered in all respects as illustrative and not restrictive. 

What is claimed:
 1. A method of identifying messages on a social networking messaging service that satisfy a search query, the method comprising: identifying at least one category relevant to the search query, wherein a plurality of scored keywords are associated with each category; selecting at least one of the scored keywords that is relevant to an identified category; performing a plurality of searches of messages from a social networking messaging service to retrieve messages, where at least one search includes retrieving messages based on the original search query and one of the selected scored keywords; scoring the retrieved messages with respect to each of the at least one identified categories using at least the scored keywords relevant to each category; and returning at least the message with the highest score as the search result.
 2. The method of claim 1, wherein the user indicates at least one category relevant to the search query.
 3. The method of claim 1, wherein the query is scored with respect to each category using the scored keywords associated with each category and at least one category is identified based upon the query score.
 4. The method of claim 1, wherein: selecting at least one of the scored keywords that is relevant to an identified category comprises selecting a plurality of scored keywords relevant to an identified category; and performing a plurality of searches of messages from a social networking messaging service further comprises performing a separate search for each of the selected scored keywords, where each search includes retrieving messages based on the original search query and the selected scored keyword.
 5. The method of claim 4, wherein performing a plurality of searches of messages from a social networking messaging service further comprises performing a search, where the messages are retrieved based on the original search query.
 6. The method of claim 1, wherein scoring the retrieved messages with respect to each of the at least one identified categories using the scored keywords relevant to each category further comprises excluding any scored keyword used in the search that retrieved the message from the scoring of the message.
 7. The method of claim 1, wherein the searches include performing expression matching.
 8. The method of claim 1, wherein the searches include scoring the message with respect to the original search query and the selected scored keyword.
 9. The method of claim 1, wherein scoring the retrieved messages further comprises weighting messages based upon the amount of time that has elapsed since the message was posted. 